package proc;

/**
 * This is the main class which runs the whole File Processing project. It contains 
 * only a main. Main uses the other classes of the project to process the primary-input, 
 * auxiliary-input, result-output, and report-output files. 
 * 
 * @author Dragon Slayer
 */
public class BasicMFP {

	/**
	 * Uses FileWrap (BasicFileWrap) to begin processing the files if there are the
	 * correct amount of arguments.
	 */
	public static void main(String[] args) {
		
		FileWrap files;
		try{
			files = new BasicFileWrap(args); //throws exception in constructor if there are an inappropriate number of args		
			if(files.checkFiles()){ //if the files are read/writeable, process them
				files.processFiles();
			}
		} catch (IllegalArgumentException e){
			System.err.print("Usage: lab1 primary-input auxiliary-input " +
					"result-output report-output");
		}		
	}
}